package org.shiwen.week5.Friday;

public class Circle {
    //属性
    double radius;
    double area;

    //构造方法
    public Circle(double radius) {
        this.radius = radius;
    }

    Circle(){
    }

    //设计方法
    void printArea(double radius){
        System.out.println("Area of circle is: " + Math.PI * radius * radius);
    }

    void printArea(){
        System.out.println("Area of circle is: " + Math.PI * radius * radius);
    }

    double showRadius(double area){
        double radius = Math.sqrt(area/Math.PI);
        return radius;
    }
}
